const collection = function (Mock) {
    function getCollectionByUser() {
        let storeList = Mock.mock({
            "array|10": [
                {
                    "id": "@id",
                    "image": "@image('100x100', @color)",
                    "storeName": '@cword(5,15)',
                    "score": '@float(0, 5, 1, 1)',
                    "monthSales": '@integer(0, 10000)',
                    "perCost": '@integer(0, 100)',
                    "minPrice": '@integer(0, 100)',
                    "shippingPrice": '@integer(0, 50)',
                    "distance": '@integer(0, 10000)',
                    "time": '@integer(0, 120)',
                }
            ]
        }).array

        return {
            storeList,
            code: 200,
        }
    }

    Mock.mock('/collection/getCollectionByUser', 'post', getCollectionByUser)
}


export default collection